package com.ssy.lingxi.fallback;

import com.ssy.lingxi.common.response.ResponseCode;
import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.dto.request.MemberSettlementStrategyRequest;
import com.ssy.lingxi.dto.response.MemberSettlementStrategyResponse;
import com.ssy.lingxi.dto.response.PlatformAccountConfigDetailVO;
import com.ssy.lingxi.feign.PlatformConfigControllerFeign;
import org.springframework.stereotype.Component;

import javax.validation.Valid;

@Component
public class PlatformConfigControllerFallback implements PlatformConfigControllerFeign {

    /**
     * 获取平台对公账户配置
     * @author 伍将
     * @date 2020/12/16
     **/
    @Override
    public Wrapper<PlatformAccountConfigDetailVO> getPlatformAccountConfig() {
        return Wrapper.fail(ResponseCode.SETTLE_ACCOUNTS_SERVICE_ERROR);
    }

    /**
     *获取会员有效结算策略(账期、月结)
     * @param memberSettlementStrategyRequest 接口参数
     * @return 查询结果
     */
    @Override
    public Wrapper<MemberSettlementStrategyResponse> getMemberSettlementStrategy(@Valid MemberSettlementStrategyRequest memberSettlementStrategyRequest) {
        return Wrapper.fail(ResponseCode.SETTLE_ACCOUNTS_SERVICE_ERROR);
    }
}
